import request from '@/utils/request'

export const regAPI = data => request.post('/api/reg', data)

export const loginAPI = data => request.post('/api/login', data)

export const getUserAPI = () => request.get('/my/userinfo')

export const getMenuAPI = () => request.get('/my/menus')

export const updateUserAPI = data => request.put('/my/userinfo', data)

export const updatePassAPI = data => request.patch('/my/updatepwd', data)

export const updateAvaterAPI = data => request.patch('/my/update/avatar', { avatar: data })
